package ua.openmedis.domain;

// Generated Aug 22, 2011 4:58:43 PM by Hibernate Tools 3.4.0.CR1

import java.util.Date;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import javax.persistence.UniqueConstraint;

/**
 * Workorders generated by hbm2java
 */
@Entity
@Table(name = "workorders", catalog = "openmedis_demo", uniqueConstraints = @UniqueConstraint(columnNames = "WorkorderNo"))
public class Workorders implements java.io.Serializable {

	private String workorderId;
	private Workstatus workstatus;
	private Workpriority workpriority;
	private Employees employees;
	private Failurecause failurecause;
	private Assets assets;
	private Worktype worktype;
	private String workorderNo;
	private String pmno;
	private String problemDescription;
	private String requesterNo;
	private Date dateReceived;
	private Integer receiverId;
	private Date estDateStart;
	private Date estDateEnd;
	private Date actDateStart;
	private Date actDateEnd;
	private Date dateRequired;
	private Date dateHandover;
	private String actionTaken;
	private String causeDescription;
	private String preventionTaken;
	private Date pmtarStartDate;
	private Date pmtarCompDate;
	private Integer wotrade;
	private Date asstartDate;
	private Date assEndDate;
	private String acceptedBy;
	private Double wolaborCost;
	private Double wodicost;
	private Double wopartCost;

	public Workorders() {
	}

	public Workorders(String workorderId) {
		this.workorderId = workorderId;
	}

	public Workorders(String workorderId, Workstatus workstatus,
			Workpriority workpriority, Employees employees,
			Failurecause failurecause, Assets assets, Worktype worktype,
			String workorderNo, String pmno, String problemDescription,
			String requesterNo, Date dateReceived, Integer receiverId,
			Date estDateStart, Date estDateEnd, Date actDateStart,
			Date actDateEnd, Date dateRequired, Date dateHandover,
			String actionTaken, String causeDescription,
			String preventionTaken, Date pmtarStartDate, Date pmtarCompDate,
			Integer wotrade, Date asstartDate, Date assEndDate,
			String acceptedBy, Double wolaborCost, Double wodicost,
			Double wopartCost) {
		this.workorderId = workorderId;
		this.workstatus = workstatus;
		this.workpriority = workpriority;
		this.employees = employees;
		this.failurecause = failurecause;
		this.assets = assets;
		this.worktype = worktype;
		this.workorderNo = workorderNo;
		this.pmno = pmno;
		this.problemDescription = problemDescription;
		this.requesterNo = requesterNo;
		this.dateReceived = dateReceived;
		this.receiverId = receiverId;
		this.estDateStart = estDateStart;
		this.estDateEnd = estDateEnd;
		this.actDateStart = actDateStart;
		this.actDateEnd = actDateEnd;
		this.dateRequired = dateRequired;
		this.dateHandover = dateHandover;
		this.actionTaken = actionTaken;
		this.causeDescription = causeDescription;
		this.preventionTaken = preventionTaken;
		this.pmtarStartDate = pmtarStartDate;
		this.pmtarCompDate = pmtarCompDate;
		this.wotrade = wotrade;
		this.asstartDate = asstartDate;
		this.assEndDate = assEndDate;
		this.acceptedBy = acceptedBy;
		this.wolaborCost = wolaborCost;
		this.wodicost = wodicost;
		this.wopartCost = wopartCost;
	}

	@Id
	@Column(name = "WorkorderID", unique = true, nullable = false, length = 36)
	public String getWorkorderId() {
		return this.workorderId;
	}

	public void setWorkorderId(String workorderId) {
		this.workorderId = workorderId;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "WorkStatusID")
	public Workstatus getWorkstatus() {
		return this.workstatus;
	}

	public void setWorkstatus(Workstatus workstatus) {
		this.workstatus = workstatus;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "WorkPriorityID")
	public Workpriority getWorkpriority() {
		return this.workpriority;
	}

	public void setWorkpriority(Workpriority workpriority) {
		this.workpriority = workpriority;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "EmployeeID")
	public Employees getEmployees() {
		return this.employees;
	}

	public void setEmployees(Employees employees) {
		this.employees = employees;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "FailureCauseID")
	public Failurecause getFailurecause() {
		return this.failurecause;
	}

	public void setFailurecause(Failurecause failurecause) {
		this.failurecause = failurecause;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "AssetID")
	public Assets getAssets() {
		return this.assets;
	}

	public void setAssets(Assets assets) {
		this.assets = assets;
	}

	@ManyToOne(fetch = FetchType.LAZY)
	@JoinColumn(name = "WorkTypeID")
	public Worktype getWorktype() {
		return this.worktype;
	}

	public void setWorktype(Worktype worktype) {
		this.worktype = worktype;
	}

	@Column(name = "WorkorderNo", unique = true, length = 50)
	public String getWorkorderNo() {
		return this.workorderNo;
	}

	public void setWorkorderNo(String workorderNo) {
		this.workorderNo = workorderNo;
	}

	@Column(name = "PMNo", length = 50)
	public String getPmno() {
		return this.pmno;
	}

	public void setPmno(String pmno) {
		this.pmno = pmno;
	}

	@Column(name = "ProblemDescription", length = 65535)
	public String getProblemDescription() {
		return this.problemDescription;
	}

	public void setProblemDescription(String problemDescription) {
		this.problemDescription = problemDescription;
	}

	@Column(name = "RequesterNo", length = 50)
	public String getRequesterNo() {
		return this.requesterNo;
	}

	public void setRequesterNo(String requesterNo) {
		this.requesterNo = requesterNo;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "DateReceived", length = 19)
	public Date getDateReceived() {
		return this.dateReceived;
	}

	public void setDateReceived(Date dateReceived) {
		this.dateReceived = dateReceived;
	}

	@Column(name = "ReceiverID")
	public Integer getReceiverId() {
		return this.receiverId;
	}

	public void setReceiverId(Integer receiverId) {
		this.receiverId = receiverId;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "EstDateStart", length = 19)
	public Date getEstDateStart() {
		return this.estDateStart;
	}

	public void setEstDateStart(Date estDateStart) {
		this.estDateStart = estDateStart;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "EstDateEnd", length = 19)
	public Date getEstDateEnd() {
		return this.estDateEnd;
	}

	public void setEstDateEnd(Date estDateEnd) {
		this.estDateEnd = estDateEnd;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "ActDateStart", length = 19)
	public Date getActDateStart() {
		return this.actDateStart;
	}

	public void setActDateStart(Date actDateStart) {
		this.actDateStart = actDateStart;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "ActDateEnd", length = 19)
	public Date getActDateEnd() {
		return this.actDateEnd;
	}

	public void setActDateEnd(Date actDateEnd) {
		this.actDateEnd = actDateEnd;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "DateRequired", length = 19)
	public Date getDateRequired() {
		return this.dateRequired;
	}

	public void setDateRequired(Date dateRequired) {
		this.dateRequired = dateRequired;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "DateHandover", length = 19)
	public Date getDateHandover() {
		return this.dateHandover;
	}

	public void setDateHandover(Date dateHandover) {
		this.dateHandover = dateHandover;
	}

	@Column(name = "ActionTaken", length = 65535)
	public String getActionTaken() {
		return this.actionTaken;
	}

	public void setActionTaken(String actionTaken) {
		this.actionTaken = actionTaken;
	}

	@Column(name = "CauseDescription", length = 65535)
	public String getCauseDescription() {
		return this.causeDescription;
	}

	public void setCauseDescription(String causeDescription) {
		this.causeDescription = causeDescription;
	}

	@Column(name = "PreventionTaken", length = 65535)
	public String getPreventionTaken() {
		return this.preventionTaken;
	}

	public void setPreventionTaken(String preventionTaken) {
		this.preventionTaken = preventionTaken;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "PMTarStartDate", length = 19)
	public Date getPmtarStartDate() {
		return this.pmtarStartDate;
	}

	public void setPmtarStartDate(Date pmtarStartDate) {
		this.pmtarStartDate = pmtarStartDate;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "PMTarCompDate", length = 19)
	public Date getPmtarCompDate() {
		return this.pmtarCompDate;
	}

	public void setPmtarCompDate(Date pmtarCompDate) {
		this.pmtarCompDate = pmtarCompDate;
	}

	@Column(name = "WOTrade")
	public Integer getWotrade() {
		return this.wotrade;
	}

	public void setWotrade(Integer wotrade) {
		this.wotrade = wotrade;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "AsstartDate", length = 19)
	public Date getAsstartDate() {
		return this.asstartDate;
	}

	public void setAsstartDate(Date asstartDate) {
		this.asstartDate = asstartDate;
	}

	@Temporal(TemporalType.TIMESTAMP)
	@Column(name = "AssEndDate", length = 19)
	public Date getAssEndDate() {
		return this.assEndDate;
	}

	public void setAssEndDate(Date assEndDate) {
		this.assEndDate = assEndDate;
	}

	@Column(name = "AcceptedBy", length = 50)
	public String getAcceptedBy() {
		return this.acceptedBy;
	}

	public void setAcceptedBy(String acceptedBy) {
		this.acceptedBy = acceptedBy;
	}

	@Column(name = "WOLaborCost", precision = 53, scale = 0)
	public Double getWolaborCost() {
		return this.wolaborCost;
	}

	public void setWolaborCost(Double wolaborCost) {
		this.wolaborCost = wolaborCost;
	}

	@Column(name = "WODICost", precision = 53, scale = 0)
	public Double getWodicost() {
		return this.wodicost;
	}

	public void setWodicost(Double wodicost) {
		this.wodicost = wodicost;
	}

	@Column(name = "WOPartCost", precision = 53, scale = 0)
	public Double getWopartCost() {
		return this.wopartCost;
	}

	public void setWopartCost(Double wopartCost) {
		this.wopartCost = wopartCost;
	}

}
